#include <stdlib.h>
#include "sikle.h"

ProgramStack* ProgramStack_new(int size)
{
  ProgramStack* ps = (ProgramStack*)malloc(sizeof(ProgramStack));
  
  ps->size = size;
  ps->bp = (Token*)malloc(size);
  ps->sp = ps->bp;

  return ps;
}

ExecStack* ExecStack_new(int size)
{
  ExecStack* es = (ExecStack*)malloc(sizeof(ExecStack));
  
  es->size = size;
  es->bp = (unsigned char*)malloc(size);
  es->sp = es->bp;

  return es;
}
